package com.itcast.demo_one.apis

import com.itcast.demo_one.model.ChannelResponse
import com.itcast.demo_one.model.LoginRequest
import com.itcast.demo_one.model.LoginResponse
import retrofit2.http.Body
import retrofit2.http.GET
import retrofit2.http.POST

interface ApiService {
    // 1. 获取频道
    @GET("channels")
    suspend fun getChannels(): ChannelResponse

    // 2. 登录操作
    @POST("login")
    suspend fun login(
        @Body body: LoginRequest
    ): LoginResponse
}